package hd.day924;

/**
 * @author oldliu
 * @since 1.0
 */
public class WrapTest {
    public static void main(String[] args) {
        //8种基本类型对应的类
        //int ==>Integer
        //double =>Double
        //char =>Character
        //boolean =>Boolean
        int i = Integer.parseInt("123");
        System.out.println(i);
        //自动装箱和拆箱
        double d=1.4;
        Double d2=d;
        double d3=d2;
//        d3=null;//error
//        d2=null;
        //parsexxx =》字符串 转换成对应的基本类型
        double d4=Double.parseDouble("4.5");
        System.out.println(d4);

        int k=100;
        String s1 = Integer.toBinaryString(k);
        System.out.println(s1);
        String s2 = Integer.toBinaryString(-k);
        System.out.println(s2);
    }
}
